#region Using
using System;
using System.Collections.Generic;
using System.Text;
using System.Collections;
#endregion Using

namespace CY.GFive.Core.Business
{
	public class Measure : Business.BusinessBase<Measure, int>
	{
		#region Fields and Properties

		private String departCode = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String DepartCode
		{
			get { return departCode; }
			set
			{
				if (value != departCode)
				{
					MarkChanged("DepartCode");
					departCode = value;
				}
			}
		}

		private String classRoomCode = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String ClassRoomCode
		{
			get { return classRoomCode; }
			set
			{
				if (value != classRoomCode)
				{
					MarkChanged("ClassRoomCode");
					classRoomCode = value;
				}
			}
		}

		private String schlCert = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String SchlCert
		{
			get { return schlCert; }
			set
			{
				if (value != schlCert)
				{
					MarkChanged("SchlCert");
					schlCert = value;
				}
			}
		}

		private int availUse = 0;
		/// <summary>
		/// 
		/// </summary>
		public int AvailUse
		{
			get { return availUse; }
			set
			{
				if (value != availUse)
				{
					MarkChanged("AvailUse");
					availUse = value;
				}
			}
		}

		private int inUse = 0;
		/// <summary>
		/// 
		/// </summary>
		public int InUse
		{
			get { return inUse; }
			set
			{
				if (value != inUse)
				{
					MarkChanged("InUse");
					inUse = value;
				}
			}
		}

		private int failureNum = 0;
		/// <summary>
		/// 
		/// </summary>
		public int FailureNum
		{
			get { return failureNum; }
			set
			{
				if (value != failureNum)
				{
					MarkChanged("FailureNum");
					failureNum = value;
				}
			}
		}

		private int qualifiedNum = 0;
		/// <summary>
		/// 
		/// </summary>
		public int QualifiedNum
		{
			get { return qualifiedNum; }
			set
			{
				if (value != qualifiedNum)
				{
					MarkChanged("QualifiedNum");
					qualifiedNum = value;
				}
			}
		}

		private String projectItem = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String ProjectItem
		{
			get { return projectItem; }
			set
			{
				if (value != projectItem)
				{
					MarkChanged("ProjectItem");
					projectItem = value;
				}
			}
		}

		private String certification = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String Certification
		{
			get { return certification; }
			set
			{
				if (value != certification)
				{
					MarkChanged("Certification");
					certification = value;
				}
			}
		}

		private DateTime facDate = DateTime.MinValue;
		/// <summary>
		/// 
		/// </summary>
		public DateTime FacDate
		{
			get { return facDate; }
			set
			{
				if (value != facDate)
				{
					MarkChanged("FacDate");
					facDate = value;
				}
			}
		}

		private String factory = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String Factory
		{
			get { return factory; }
			set
			{
				if (value != factory)
				{
					MarkChanged("Factory");
					factory = value;
				}
			}
		}

		private int num = 0;
		/// <summary>
		/// 
		/// </summary>
		public int Num
		{
			get { return num; }
			set
			{
				if (value != num)
				{
					MarkChanged("Num");
					num = value;
				}
			}
		}

		private String precision = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String Precision
		{
			get { return precision; }
			set
			{
				if (value != precision)
				{
					MarkChanged("Precision");
					precision = value;
				}
			}
		}

		private String format = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String Format
		{
			get { return format; }
			set
			{
				if (value != format)
				{
					MarkChanged("Format");
					format = value;
				}
			}
		}

		private String schlCode = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String SchlCode
		{
			get { return schlCode; }
			set
			{
				if (value != schlCode)
				{
					MarkChanged("SchlCode");
					schlCode = value;
				}
			}
		}

		private String facCode = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String FacCode
		{
			get { return facCode; }
			set
			{
				if (value != facCode)
				{
					MarkChanged("FacCode");
					facCode = value;
				}
			}
		}

		private String measureName = String.Empty;
		/// <summary>
		/// 
		/// </summary>
		public String MeasureName
		{
			get { return measureName; }
			set
			{
				if (value != measureName)
				{
					MarkChanged("MeasureName");
					measureName = value;
				}
			}
		}

		#endregion Fields and Properties

		#region Constructors

		public Measure()
		{
		}

		#endregion Constructors

		#region Base overrides

		protected override void ValidationRules()
		{
		}

		protected override Measure DataSelect(int id)
		{
			return Services.DALService.MeasureService.Select(id);
		}

		protected override void DataUpdate()
		{
			Services.DALService.MeasureService.Update(this);
		}

		protected override void DataInsert()
		{
			Services.DALService.MeasureService.Insert(this);
		}

		protected override void DataDelete()
		{
			Services.DALService.MeasureService.Delete(this);
		}

		#endregion Base overrides
	}
}
